Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Testing PR to check rebase against latest on maint/maint-75 for: Memory error handling #64

Open
wants to merge 6 commits into
base: maint/maint-75
Choose a base branch
from

Conversation

echeran
Copy link
Owner

@echeran echeran commented Apr 11, 2024

No description provided.

catamorphism and others added 6 commits March 29, 2024 14:54
Previously, there were separate overrides for the options and
attributes parsing methods in the parser that were used in different
context. (Options can appear in Operator and Markup, while attributes
can appear in Expression and Markup.)

This is a refactoring that eliminates this duplicated code.
To enable it, a builder is added for the internal OptionMap type.
This is necessary for compilation on Windows, even though it's
an internal class
…unctions

Several functions used to copy between vectors and arrays were written
not to take a UErrorCode, but rather to take an int argument by reference
and set it to 0 to indicate a memory allocation error. To be more
consistent with ICU style, change these functions to take a UErrorCode
argument.

Several data model classes (Reserved, Matcher and Pattern) are also
modified to add a `bogus` flag to indicate that a copy failed. Previously,
the "bogus" state was denoted by setting an internal length field to 0,
but that was wrong because a valid instance of these classes can have
length 0 and that state should be distinguished from an uninitialized
state.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants